import 'package:flutter/material.dart';
import 'package:get/get.dart';
import 'package:tools/tools.dart';

import '../controllers/video_controller.dart';

class VideoView extends GetView<VideoController> {
  const VideoView({Key? key}) : super(key: key);
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: const Text('VideoView'),
        centerTitle: true,
      ),
      body: VideoWidget(
        controller: controller.videoWidgetController,
        url:
            'https://tcdn.zhoubo.vip/files/4c138b211b577fa3ec4d50c2e3107f7f.mp4',
        autoPlay: true,
        width: context.width,
        // height: Get.height,
        radius: 20,
        showIcon: true,
        fit: BoxFit.fitWidth,
        schedules: true,
      ),
    );
  }
}
